using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._RasterAnalysisTools._AnalyzeTerrain
{
    /// <summary>
    /// <para>Create Viewshed</para>
    /// <para>Creates areas where an observer can see objects on the ground. The input observer points can represent either observers (such as people on the ground or lookouts in a fire tower) or observed objects (such as wind turbines, water towers, vehicles, or other people).</para>
    /// <para>创建观察者可以看到地面上物体的区域。输入观察点可以表示观察点（例如地面上的人或消防塔中的瞭望台）或观察对象（例如风力涡轮机、水塔、车辆或其他人）。</para>
    /// </summary>    
    [DisplayName("Create Viewshed")]
    public class CreateViewshed : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public CreateViewshed()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_inputElevationSurface">
        /// <para>Input Elevation Surface</para>
        /// <para><xdoc>
        ///   <para>The elevation surface to use for calculating the viewshed.</para>
        ///   <para>If the vertical unit of the input surface is different from the horizontal unit, such as when the elevation values are represented in feet but the coordinate system is in meters, the surface must have a defined vertical coordinate system. The reason for this is that the tool uses the vertical (Z) and horizontal (XY) units to compute a z-factor for the viewshed analysis. Without a vertical coordinate system, and thus having no Z unit information available, the tool will assume that the Z unit is the same as the XY unit. The result of this is that an internal Z factor of 1.0 will be used for the analysis, which may give unexpected results.</para>
        ///   <para>The elevation surface can be integer or floating point.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>用于计算视域的高程表面。</para>
        ///   <para>如果输入表面的垂直单位与水平单位不同，例如，当高程值以英尺表示但坐标系以米表示时，则表面必须具有定义的垂直坐标系。原因是该工具使用垂直 （Z） 和水平 （XY） 单位来计算视域分析的 z 因子。如果没有垂直坐标系，因此没有可用的 Z 单位信息，该工具将假定 Z 单位与 XY 单位相同。这样做的结果是，内部 Z 因子为 1.0 将用于分析，这可能会产生意想不到的结果。</para>
        ///   <para>高程表面可以是整数或浮点。</para>
        /// </xdoc></para>
        /// </param>
        /// <param name="_inputObserverFeatures">
        /// <para>Observer Features</para>
        /// <para>The point features that represent the observer locations when calculating the viewsheds.</para>
        /// <para>计算视域时表示观察点位置的点要素。</para>
        /// </param>
        /// <param name="_outputName">
        /// <para>Output Name</para>
        /// <para><xdoc>
        ///   <para>The name of the output raster service.</para>
        ///   <para>The default name is based on the tool name and the input layer name. If the layer name already exists, you will be prompted to provide another name.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>输出栅格服务的名称。</para>
        ///   <para>默认名称基于工具名称和输入图层名称。如果图层名称已存在，系统将提示您提供其他名称。</para>
        /// </xdoc></para>
        /// </param>
        public CreateViewshed(object _inputElevationSurface, object _inputObserverFeatures, object _outputName)
        {
            this._inputElevationSurface = _inputElevationSurface;
            this._inputObserverFeatures = _inputObserverFeatures;
            this._outputName = _outputName;
        }
        public override string ToolboxName => "Raster Analysis Tools";

        public override string ToolName => "Create Viewshed";

        public override string CallName => "ra.CreateViewshed";

        public override List<string> AcceptEnvironments => ["cellSize", "extent", "mask", "outputCoordinateSystem", "snapRaster"];

        public override object[] ParameterInfo => [_inputElevationSurface, _inputObserverFeatures, _outputName, _optimizeFor.GetGPValue(), _maximumViewingDistanceType.GetGPValue(), _maximumViewingDistance, _maximumViewingDistanceField, _minimumViewingDistanceType.GetGPValue(), _minimumViewingDistance, _minimumViewingDistanceField, _viewingDistanceIs3D.GetGPValue(), _observersElevationType.GetGPValue(), _observersElevation, _observersElevationField, _observersHeightType.GetGPValue(), _observersHeight, _observersHeightField, _targetHeightType.GetGPValue(), _targetHeight, _targetHeightField, _aboveGroundLevelOutputName, _outputRaster, _outputAboveGroundLevelRaster];

        /// <summary>
        /// <para>Input Elevation Surface</para>
        /// <para><xdoc>
        ///   <para>The elevation surface to use for calculating the viewshed.</para>
        ///   <para>If the vertical unit of the input surface is different from the horizontal unit, such as when the elevation values are represented in feet but the coordinate system is in meters, the surface must have a defined vertical coordinate system. The reason for this is that the tool uses the vertical (Z) and horizontal (XY) units to compute a z-factor for the viewshed analysis. Without a vertical coordinate system, and thus having no Z unit information available, the tool will assume that the Z unit is the same as the XY unit. The result of this is that an internal Z factor of 1.0 will be used for the analysis, which may give unexpected results.</para>
        ///   <para>The elevation surface can be integer or floating point.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>用于计算视域的高程表面。</para>
        ///   <para>如果输入表面的垂直单位与水平单位不同，例如，当高程值以英尺表示但坐标系以米表示时，则表面必须具有定义的垂直坐标系。原因是该工具使用垂直 （Z） 和水平 （XY） 单位来计算视域分析的 z 因子。如果没有垂直坐标系，因此没有可用的 Z 单位信息，该工具将假定 Z 单位与 XY 单位相同。这样做的结果是，内部 Z 因子为 1.0 将用于分析，这可能会产生意想不到的结果。</para>
        ///   <para>高程表面可以是整数或浮点。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Elevation Surface")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _inputElevationSurface { get; set; }


        /// <summary>
        /// <para>Observer Features</para>
        /// <para>The point features that represent the observer locations when calculating the viewsheds.</para>
        /// <para>计算视域时表示观察点位置的点要素。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Observer Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _inputObserverFeatures { get; set; }


        /// <summary>
        /// <para>Output Name</para>
        /// <para><xdoc>
        ///   <para>The name of the output raster service.</para>
        ///   <para>The default name is based on the tool name and the input layer name. If the layer name already exists, you will be prompted to provide another name.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>输出栅格服务的名称。</para>
        ///   <para>默认名称基于工具名称和输入图层名称。如果图层名称已存在，系统将提示您提供其他名称。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Name")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _outputName { get; set; }


        /// <summary>
        /// <para>Optimize For</para>
        /// <para><xdoc>
        ///   <para>The optimization method to use for calculating the viewshed.</para>
        ///   <bulletList>
        ///     <bullet_item>Speed—This method optimizes the processing speed, trading some accuracy in the result for higher performance. This is the default.</bullet_item><para/>
        ///     <bullet_item>Accuracy—This method is optimized for accuracy in the results, at the expense of a longer processing time.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>用于计算视域的优化方法。</para>
        ///   <bulletList>
        ///     <bullet_item>速度 - 此方法可优化处理速度，在结果中牺牲一些准确性以换取更高的性能。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>准确性 - 此方法针对结果的准确性进行了优化，但代价是处理时间更长。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Optimize For")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _optimizeFor_value _optimizeFor { get; set; } = _optimizeFor_value._SPEED;

        public enum _optimizeFor_value
        {
            /// <summary>
            /// <para>Speed</para>
            /// <para>Speed—This method optimizes the processing speed, trading some accuracy in the result for higher performance. This is the default.</para>
            /// <para>速度 - 此方法可优化处理速度，在结果中牺牲一些准确性以换取更高的性能。这是默认设置。</para>
            /// </summary>
            [Description("Speed")]
            [GPEnumValue("SPEED")]
            _SPEED,

            /// <summary>
            /// <para>Accuracy</para>
            /// <para>Accuracy—This method is optimized for accuracy in the results, at the expense of a longer processing time.</para>
            /// <para>准确性 - 此方法针对结果的准确性进行了优化，但代价是处理时间更长。</para>
            /// </summary>
            [Description("Accuracy")]
            [GPEnumValue("ACCURACY")]
            _ACCURACY,

        }

        /// <summary>
        /// <para>Maximum Viewing Distance Type</para>
        /// <para><xdoc>
        ///   <para>The method by which the maximum viewing distance will be determined.</para>
        ///   <bulletList>
        ///     <bullet_item>Distance—The maximum distance is defined by a value you specify. This is the default method.</bullet_item><para/>
        ///     <bullet_item>Field— The maximum distance for each observer location is determined by the values in a field you specify.</bullet_item><para/>
        ///   </bulletList>
        ///   <para>If you change the type from Distance to Field, the Maximum Viewing Distance parameter will change to Maximum Viewing Distance Field.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>确定最大观看距离的方法。</para>
        ///   <bulletList>
        ///     <bullet_item>距离 - 最大距离由您指定的值定义。这是默认方法。</bullet_item><para/>
        ///     <bullet_item>字段 - 每个观察点位置的最大距离由您指定的字段中的值确定。</bullet_item><para/>
        ///   </bulletList>
        ///   <para>如果将类型从“距离”更改为“视场”，则“最大可视距离”参数将更改为“最大可视距离”视场。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Maximum Viewing Distance Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _maximumViewingDistanceType_value _maximumViewingDistanceType { get; set; } = _maximumViewingDistanceType_value._DISTANCE;

        public enum _maximumViewingDistanceType_value
        {
            /// <summary>
            /// <para>Distance</para>
            /// <para>Distance—The maximum distance is defined by a value you specify. This is the default method.</para>
            /// <para>距离 - 最大距离由您指定的值定义。这是默认方法。</para>
            /// </summary>
            [Description("Distance")]
            [GPEnumValue("DISTANCE")]
            _DISTANCE,

            /// <summary>
            /// <para>Field</para>
            /// <para>Field— The maximum distance for each observer location is determined by the values in a field you specify.</para>
            /// <para>字段 - 每个观察点位置的最大距离由您指定的字段中的值确定。</para>
            /// </summary>
            [Description("Field")]
            [GPEnumValue("FIELD")]
            _FIELD,

        }

        /// <summary>
        /// <para>Maximum Viewing Distance</para>
        /// <para><xdoc>
        ///   <para>This is a cutoff distance, where the computation of visible areas stops. Beyond this distance, it is unknown whether the observer points and the other objects can see each other.</para>
        ///   <para>The units can be Kilometers, Meters, Miles, Yards, or Feet.</para>
        ///   <para>The default is miles.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>这是一个截止距离，可见区域的计算停止。超过这个距离，观察者点和其他物体是否能看到对方是未知的。</para>
        ///   <para>单位可以是公里、米、英里、码或英尺。</para>
        ///   <para>默认值为英里。</para>
        /// </xdoc></para>
        /// <para>单位： Meters | Kilometers | Feet | Yards | Miles </para>
        /// </summary>
        [DisplayName("Maximum Viewing Distance")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string _maximumViewingDistance { get; set; } = "9 Miles";


        /// <summary>
        /// <para>Maximum Viewing Distance Field</para>
        /// <para><xdoc>
        ///   <para>This is a field you can use to specify the maximum viewing distance for each observer. The values contained in the field must be in the same unit as the XY unit of the input elevation surface.</para>
        ///   <para>The maximum viewing distance is a cutoff distance where the computation of visible areas stops. Beyond this distance, it is unknown whether the observer points and the other objects can see each other.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>此字段可用于指定每个观察点的最大观看距离。字段中包含的值必须与输入高程表面的 XY 单位采用相同的单位。</para>
        ///   <para>最大观看距离是可见区域计算停止的截止距离。超过这个距离，观察者点和其他物体是否能看到对方是未知的。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Maximum Viewing Distance Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _maximumViewingDistanceField { get; set; } = null;


        /// <summary>
        /// <para>Minimum Viewing Distance Type</para>
        /// <para><xdoc>
        ///   <para>Choose the method by which the minimum visible distance will be determined.</para>
        ///   <bulletList>
        ///     <bullet_item>Distance—The minimum distance is defined by a value you specify. This is the default method.</bullet_item><para/>
        ///     <bullet_item>Field— The minimum distance for each observer location is determined by the values in a field you specify.</bullet_item><para/>
        ///   </bulletList>
        ///   <para>If you change the type from Distance to Field, the Minimum Viewing Distance parameter will change to Minimum Viewing Distance Field.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>选择确定最小可见距离的方法。</para>
        ///   <bulletList>
        ///     <bullet_item>距离 - 最小距离由您指定的值定义。这是默认方法。</bullet_item><para/>
        ///     <bullet_item>字段 - 每个观察点位置的最小距离由您指定的字段中的值确定。</bullet_item><para/>
        ///   </bulletList>
        ///   <para>如果将类型从“距离”更改为“字段”，则“最小观看距离”参数将更改为“最小观看距离字段”。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Minimum Viewing Distance Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _minimumViewingDistanceType_value _minimumViewingDistanceType { get; set; } = _minimumViewingDistanceType_value._DISTANCE;

        public enum _minimumViewingDistanceType_value
        {
            /// <summary>
            /// <para>Distance</para>
            /// <para>Distance—The minimum distance is defined by a value you specify. This is the default method.</para>
            /// <para>距离 - 最小距离由您指定的值定义。这是默认方法。</para>
            /// </summary>
            [Description("Distance")]
            [GPEnumValue("DISTANCE")]
            _DISTANCE,

            /// <summary>
            /// <para>Field</para>
            /// <para>Field— The minimum distance for each observer location is determined by the values in a field you specify.</para>
            /// <para>字段 - 每个观察点位置的最小距离由您指定的字段中的值确定。</para>
            /// </summary>
            [Description("Field")]
            [GPEnumValue("FIELD")]
            _FIELD,

        }

        /// <summary>
        /// <para>Minimum Viewing Distance</para>
        /// <para><xdoc>
        ///   <para>This is a distance where the computation of visible areas begins. Cells on the surface closer than this distance are not visible in the output but can still block visibility of the cells between the minimum and maximum viewing distance.</para>
        ///   <para>The units can be Kilometers, Meters, Miles, Yards, or Feet.</para>
        ///   <para>The default units are Meters.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>这是开始计算可见区域的距离。表面上小于此距离的像元在输出中不可见，但仍会阻挡最小和最大可视距离之间的像元可见性。</para>
        ///   <para>单位可以是公里、米、英里、码或英尺。</para>
        ///   <para>默认单位为米。</para>
        /// </xdoc></para>
        /// <para>单位： Meters | Kilometers | Feet | Yards | Miles </para>
        /// </summary>
        [DisplayName("Minimum Viewing Distance")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _minimumViewingDistance { get; set; } = null;


        /// <summary>
        /// <para>Minimum Viewing Distance Field</para>
        /// <para><xdoc>
        ///   <para>This is a field you can use to specify the minimum viewing distance for each observer. The values contained in the field must be in the same unit as the XY unit of the input elevation surface.</para>
        ///   <para>The minimum viewing distance defines where the computation of visible areas begins. Cells on the surface closer than this distance are not visible in the output but can still block visibility of the cells between the minimum and maximum viewing distance.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>此字段可用于指定每个观察点的最小观看距离。字段中包含的值必须与输入高程表面的 XY 单位采用相同的单位。</para>
        ///   <para>最小观看距离定义了可见区域计算的开始位置。表面上小于此距离的像元在输出中不可见，但仍会阻挡最小和最大可视距离之间的像元可见性。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Minimum Viewing Distance Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _minimumViewingDistanceField { get; set; } = null;


        /// <summary>
        /// <para>Viewing Distance is 3D</para>
        /// <para><xdoc>
        ///   <para>Specify whether the minimum and maximum viewing distance parameters are measured in a three-dimensional way or a simpler, two-dimensional way. A 2D distance is the simple linear distance measured between an observer and the target using their projected locations at sea level. A 3D distance gives a more realistic value by taking their relative heights into consideration.</para>
        ///   <bulletList>
        ///     <bullet_item>Checked—The viewing distance is measured in 3D distance.</bullet_item><para/>
        ///     <bullet_item>Unchecked—The viewing distance is measured in 2D distance. This is the default.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定是以三维方式还是以更简单的二维方式测量最小和最大观看距离参数。二维距离是观察者和目标之间使用他们在海平面上的投影位置测量的简单线性距离。3D 距离通过考虑它们的相对高度来提供更真实的值。</para>
        ///   <bulletList>
        ///     <bullet_item>选中 - 以 3D 距离测量查看距离。</bullet_item><para/>
        ///     <bullet_item>未选中 - 以 2D 距离测量查看距离。这是默认设置。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Viewing Distance is 3D")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _viewingDistanceIs3D_value _viewingDistanceIs3D { get; set; } = _viewingDistanceIs3D_value._false;

        public enum _viewingDistanceIs3D_value
        {
            /// <summary>
            /// <para>3D</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("3D")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>2D</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("2D")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Observers Elevation Type</para>
        /// <para><xdoc>
        ///   <para>The method by which the elevation of the observers will be determined.</para>
        ///   <bulletList>
        ///     <bullet_item>Elevation—The observer elevation is defined by a value you specify. This is the default method.</bullet_item><para/>
        ///     <bullet_item>Field—The elevation for each observer location is determined by the values in a field you specify.</bullet_item><para/>
        ///   </bulletList>
        ///   <para>If you change the type from Elevation to Field, the Observers Elevation parameter will change to Observers Elevation Field.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>确定观察点高程的方法。</para>
        ///   <bulletList>
        ///     <bullet_item>高程 - 观察点高程由您指定的值定义。这是默认方法。</bullet_item><para/>
        ///     <bullet_item>字段 - 每个观察点位置的高程由您指定的字段中的值确定。</bullet_item><para/>
        ///   </bulletList>
        ///   <para>如果将类型从“高程”更改为“字段”，则“观察点高程”参数将更改为“观察点高程字段”。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Observers Elevation Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _observersElevationType_value _observersElevationType { get; set; } = _observersElevationType_value._ELEVATION;

        public enum _observersElevationType_value
        {
            /// <summary>
            /// <para>Elevation</para>
            /// <para>Elevation—The observer elevation is defined by a value you specify. This is the default method.</para>
            /// <para>高程 - 观察点高程由您指定的值定义。这是默认方法。</para>
            /// </summary>
            [Description("Elevation")]
            [GPEnumValue("ELEVATION")]
            _ELEVATION,

            /// <summary>
            /// <para>Field</para>
            /// <para>Field—The elevation for each observer location is determined by the values in a field you specify.</para>
            /// <para>字段 - 每个观察点位置的高程由您指定的字段中的值确定。</para>
            /// </summary>
            [Description("Field")]
            [GPEnumValue("FIELD")]
            _FIELD,

        }

        /// <summary>
        /// <para>Observers Elevation</para>
        /// <para><xdoc>
        ///   <para>This is the elevation of your observer locations.</para>
        ///   <para>If this parameter is not specified, the observer elevation will be obtained from the surface raster using bilinear interpolation. If this parameter is set to a value, that value will be applied to all the observers. To specify different values for each observer, set this parameter to a field in the input observer features.</para>
        ///   <para>The units can be Kilometers, Meters, Miles, Yards, or Feet.</para>
        ///   <para>The default units are Meters.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>这是观察点位置的高程。</para>
        ///   <para>如果未指定此参数，则将使用双线性插值从表面栅格获取观测点高程。如果此参数设置为某个值，则该值将应用于所有观察点。要为每个观察点指定不同的值，请将此参数设置为输入观察点要素中的字段。</para>
        ///   <para>单位可以是公里、米、英里、码或英尺。</para>
        ///   <para>默认单位为米。</para>
        /// </xdoc></para>
        /// <para>单位： Meters | Kilometers | Feet | Yards | Miles </para>
        /// </summary>
        [DisplayName("Observers Elevation")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _observersElevation { get; set; } = null;


        /// <summary>
        /// <para>Observers Elevation Field</para>
        /// <para><xdoc>
        ///   <para>This is a field you can use to specify the elevation for the observers. The value contained in the field must be in the same unit as the Z unit of the input elevation surface.</para>
        ///   <para>If this parameter is not specified, the observer elevation will be obtained from the surface raster using bilinear interpolation.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>此字段可用于指定观察点的高程。字段中包含的值必须与输入高程表面的 Z 单位相同。</para>
        ///   <para>如果未指定此参数，则将使用双线性插值从表面栅格获取观测点高程。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Observers Elevation Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _observersElevationField { get; set; } = null;


        /// <summary>
        /// <para>Observers Height Type</para>
        /// <para><xdoc>
        ///   <para>The method by which the height of the observers will be determined.</para>
        ///   <bulletList>
        ///     <bullet_item>Height—The observer height is obtained from the value you specify. This is the default method.</bullet_item><para/>
        ///     <bullet_item>Field— The height for each observer location is determined by the values in a field you specify.</bullet_item><para/>
        ///   </bulletList>
        ///   <para>If you change the type from Height to Field, the Observers Height parameter will change to Observers Height Field.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>确定观察者高度的方法。</para>
        ///   <bulletList>
        ///     <bullet_item>高度 - 观察点高度从您指定的值中获取。这是默认方法。</bullet_item><para/>
        ///     <bullet_item>字段 - 每个观察点位置的高度由您指定的字段中的值确定。</bullet_item><para/>
        ///   </bulletList>
        ///   <para>如果将类型从“高度”更改为“字段”，则“观察点高度”参数将更改为“观察点高度字段”。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Observers Height Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _observersHeightType_value _observersHeightType { get; set; } = _observersHeightType_value._HEIGHT;

        public enum _observersHeightType_value
        {
            /// <summary>
            /// <para>Height</para>
            /// <para>Height—The observer height is obtained from the value you specify. This is the default method.</para>
            /// <para>高度 - 观察点高度从您指定的值中获取。这是默认方法。</para>
            /// </summary>
            [Description("Height")]
            [GPEnumValue("HEIGHT")]
            _HEIGHT,

            /// <summary>
            /// <para>Field</para>
            /// <para>Field— The height for each observer location is determined by the values in a field you specify.</para>
            /// <para>字段 - 每个观察点位置的高度由您指定的字段中的值确定。</para>
            /// </summary>
            [Description("Field")]
            [GPEnumValue("FIELD")]
            _FIELD,

        }

        /// <summary>
        /// <para>Observers Height</para>
        /// <para><xdoc>
        ///   <para>This is the height used for your observer locations.</para>
        ///   <para>The units can be Kilometers, Meters, Miles, Yards, or Feet.</para>
        ///   <para>The default units are Meters.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>这是用于观察点位置的高度。</para>
        ///   <para>单位可以是公里、米、英里、码或英尺。</para>
        ///   <para>默认单位为米。</para>
        /// </xdoc></para>
        /// <para>单位： Meters | Kilometers | Feet | Yards | Miles </para>
        /// </summary>
        [DisplayName("Observers Height")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string _observersHeight { get; set; } = "6 Feet";


        /// <summary>
        /// <para>Observers Height Field</para>
        /// <para>This is a field you can use to specify the height for the observers. The value contained in the field must be in the same unit as the Z unit of the input elevation surface.</para>
        /// <para>此字段可用于指定观察点的高度。字段中包含的值必须与输入高程表面的 Z 单位相同。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Observers Height Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _observersHeightField { get; set; } = null;


        /// <summary>
        /// <para>Target Height Type</para>
        /// <para><xdoc>
        ///   <para>The method by which the height of the targets will be determined.</para>
        ///   <bulletList>
        ///     <bullet_item>Height—The target height is obtained from the value you specify. This is the default method.</bullet_item><para/>
        ///     <bullet_item>Field— The height for each target is determined by the values in a field you specify.</bullet_item><para/>
        ///   </bulletList>
        ///   <para>If you change the type from Height to Field, the Target Height parameter will change to Target Height Field.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>确定目标高度的方法。</para>
        ///   <bulletList>
        ///     <bullet_item>高度 - 目标高度是从您指定的值中获取的。这是默认方法。</bullet_item><para/>
        ///     <bullet_item>字段 — 每个目标的高度由指定字段中的值确定。</bullet_item><para/>
        ///   </bulletList>
        ///   <para>如果将类型从“高度”更改为“字段”，则“目标高度”参数将更改为“目标高度字段”。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Target Height Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _targetHeightType_value _targetHeightType { get; set; } = _targetHeightType_value._HEIGHT;

        public enum _targetHeightType_value
        {
            /// <summary>
            /// <para>Height</para>
            /// <para>Height—The target height is obtained from the value you specify. This is the default method.</para>
            /// <para>高度 - 目标高度是从您指定的值中获取的。这是默认方法。</para>
            /// </summary>
            [Description("Height")]
            [GPEnumValue("HEIGHT")]
            _HEIGHT,

            /// <summary>
            /// <para>Field</para>
            /// <para>Field— The height for each target is determined by the values in a field you specify.</para>
            /// <para>字段 — 每个目标的高度由指定字段中的值确定。</para>
            /// </summary>
            [Description("Field")]
            [GPEnumValue("FIELD")]
            _FIELD,

        }

        /// <summary>
        /// <para>Target Height</para>
        /// <para><xdoc>
        ///   <para>This is the height of structures or people on the ground used to establish visibility. The result viewshed are those areas where an observer point can see these other objects. The converse is also true; the other objects can see an observer point.</para>
        ///   <para>The units can be Kilometers, Meters, Miles, Yards, or Feet.</para>
        ///   <para>The default units are Meters.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>这是用于建立能见度的地面上建筑物或人员的高度。结果视域是观察点可以看到这些其他对象的区域。反之亦然;其他对象可以看到观察点。</para>
        ///   <para>单位可以是公里、米、英里、码或英尺。</para>
        ///   <para>默认单位为米。</para>
        /// </xdoc></para>
        /// <para>单位： Meters | Kilometers | Feet | Yards | Miles </para>
        /// </summary>
        [DisplayName("Target Height")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _targetHeight { get; set; } = null;


        /// <summary>
        /// <para>Target Height Field</para>
        /// <para>This is a field used to specify the height for the targets. The value contained in the field must be in the same unit as the Z unit of the input elevation surface.</para>
        /// <para>此字段用于指定目标的高度。字段中包含的值必须与输入高程表面的 Z 单位相同。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Target Height Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _targetHeightField { get; set; } = null;


        /// <summary>
        /// <para>Above Ground Level Output Name</para>
        /// <para>The name of the output aboveground-level (AGL) raster. The AGL result is a raster where each cell value is the minimum height that must be added to an otherwise nonvisible cell to make it visible by at least one observer. Cells that were already visible will be assigned 0 in this output raster.</para>
        /// <para>输出地上 （AGL） 栅格的名称。AGL 结果是一个栅格，其中每个像元值都是必须添加到原本不可见的像元的最小高度，才能使其至少被一个观察者看到。在此输出栅格中，已可见的像元将被指定为 0。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Above Ground Level Output Name")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _aboveGroundLevelOutputName { get; set; } = null;


        /// <summary>
        /// <para>Output Raster</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Raster")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _outputRaster { get; set; }


        /// <summary>
        /// <para>Output Above Ground Level Raster</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Above Ground Level Raster")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _outputAboveGroundLevelRaster { get; set; }


        public CreateViewshed SetEnv(object cellSize = null, object extent = null, object mask = null, object outputCoordinateSystem = null, object snapRaster = null)
        {
            base.SetEnv(cellSize: cellSize, extent: extent, mask: mask, outputCoordinateSystem: outputCoordinateSystem, snapRaster: snapRaster);
            return this;
        }

    }

}